<%@page import="com.shsh.safemanage.util.Constants"%>
<%@page import="com.shsh.safemanage.model.PostcheckPattern"%>
<%@page import="java.util.List"%>
<%@page import="com.shsh.safemanage.dao.DaoCreator"%>
<%@page import="com.shsh.safemanage.dao.PostCheckDao"%>
<%@ page language="java" pageEncoding="UTF-8"%>

<%
{
	
PostCheckDao postcheckDao = DaoCreator.createPostCheckDao();


Long thePostcheckID = 0L;
Long thePostcheckPatternID = 0L;
String postcheckIDStr = (String)request.getParameter(Constants.REQUEST_PARAMETER_POSTCHECK_ID);
String postcheckPatternIDStr = (String)request.getParameter(Constants.REQUEST_PARAMETER_POSTCHECK_PATTERN_ID);
try{
	thePostcheckID = Long.parseLong(postcheckIDStr);
}catch(Exception e){
	
}
List<PostcheckPattern> patternList = postcheckDao.getPostcheckPatternByPostcheckID(thePostcheckID);
try{
	thePostcheckPatternID = Long.parseLong(postcheckPatternIDStr);
}catch(Exception e){
	
}
%>
<select id="postcheckPattern" onchange="selectPattern();">
<%
for (PostcheckPattern pattern: patternList) {
%>
	<option value="<%=pattern.getId()%>" <%=thePostcheckPatternID.equals(pattern.getId())? "selected":""%>><%=pattern.getPattern()%></option>
<%
}
%>
</select>
<%
}
%>